/**
 * 
 */
package main;

import java.awt.BorderLayout;
import java.awt.Dimension;
import java.awt.Image;
import java.awt.Toolkit;

import javax.swing.JDialog;
import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.SwingUtilities;
import javax.swing.UIManager;

import verwaltung.Einlesen;
import view.Uebersicht;

/**
 * 
 * 
 * @date 03.08.2012
 * @author rs
 * @version
 * 
 */
public class Main {

	private JFrame mainFrame;
	
	private Einlesen einlesen;
	private JPanel pnlUebersicht;

	/**
	 * Konstruktor
	 */
	public Main() {

		// Aussehen
		try {
			UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
		} catch (Exception e) {

		}

		einlesen = new Einlesen();
		
		pnlUebersicht = new Uebersicht(einlesen);
		
		mainFrame = new JFrame("Stunden");
		mainFrame.getContentPane().setLayout(new BorderLayout(5, 5));
		mainFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		
		mainFrame.add(pnlUebersicht);
		
		SwingUtilities.invokeLater(new Runnable() {
			public void run() {
				mainFrame.pack();

				mainFrame.setLocationRelativeTo(null); // in der mitte

				mainFrame.setVisible(true);
			}
		});

	}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		new Main();

	}

}
